
package com.quartet.utils.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * <p>
 * 轨迹类型
 * </p>
 * @author Zheng Jie
 * @date 2020-05-07
 */
@Getter
@AllArgsConstructor
public enum TrajectoryTypeEnum {

    TRAJECTORY_POINT("1", "轨迹点"),
    CURVE("2", "曲线"),
    PARKING("3", "停车"),
    REPORT_ALARM("4", "报警"),
    REGION("5", "区域"),
    OVER_SPEED("6", "超速"),
    FATIGUE("7", "疲劳"),
    ACTIVE_SAFETY("8", "主动安全"),
    PHOTO("9", "照片");
    private final String value;
    private final String description;

    public static TrajectoryTypeEnum find(String val) {
        for (TrajectoryTypeEnum dataScopeEnum : TrajectoryTypeEnum.values()) {
            if (val.equals(dataScopeEnum.getValue())) {
                return dataScopeEnum;
            }
        }
        return null;
    }

}
